home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1996 February / EnigmA AMIGA RUN 04 (1996)(G.R. Edizioni)(IT)[!][issue 1996-02][Skylink CD III].iso / earcd / patches / ip20t21a.lha / IFX20to21a_Patch / UnInstall_ImageFX < prev    next >
Text File  |  1995-04-11  |  3KB  |  104 lines

  1. ; ImageFX UnInstall Utility
  2. ;
  3. ; Written by Thomas Krehbiel
  4. ; Copyright © 1995 Nova Design, Inc.
  5. ;
  6.  
  7. (
  8.  
  9.    ;================================================================
  10.    ; Setup
  11.    ;================================================================
  12.  
  13.    ; script variables...
  14.  
  15.    (set programname "ImageFX")               ; name of program
  16.    (set assignname "ImageFX")                ; assignment
  17.  
  18.    ; system information...
  19.  
  20.    (set osver (/ (getversion) 65536))        ; os version
  21.    (set cputype (database "cpu"))            ; cpu type
  22.  
  23.    ;-------------------
  24.    ; Pick a default directory for the installation...
  25.    (set initialdir @default-dest)            ; defaults to biggest drive
  26.    (if (getassign "ImageFX")
  27.       (
  28.          (set initialdir (getassign "ImageFX"))
  29.       )
  30.       ; else
  31.       (
  32.          (if (getassign "ImageFX2")
  33.             (
  34.                (set initialdir (getassign "ImageFX2"))
  35.                (set assignname "ImageFX2")
  36.             )
  37.          )
  38.       )
  39.    )
  40.  
  41.    ;-------------------
  42.    ; Ask where to (un)install from...
  43.    (set wheredir
  44.       (askdir
  45.          (prompt "Please confirm the directory containing the " programname
  46.                  " software you would like to remove.")
  47.          (help "Locate the directory containing the version of " programname
  48.                "you would like to remove.")
  49.          (default initialdir)
  50.       )
  51.    )
  52.  
  53.    ; I wish there was some way we could read the tool type to get the assign
  54.    ; name... oh well.
  55.  
  56.    (if (> @user-level 1)
  57.       (
  58.          (set theassign
  59.             (askstring
  60.                (prompt "Confirm the Assign name for this ImageFX drawer: "
  61.                        "(Do NOT include a trailing colon (:)!)")
  62.                (help @askstring-help)
  63.                (default assignname)
  64.             )
  65.          )
  66.       )
  67.       ; else
  68.       (
  69.          (set theassign assignname)
  70.       )
  71.    )
  72.  
  73.    (message "ALL components of ImageFX in the drawer " wheredir " will now "
  74.             "be removed.  To abort, click on `Abort Install' now.")
  75.  
  76.    ; Remove the assign so we can delete the directory
  77.    (run ("Assign %ls:" theassign))
  78.  
  79.    (run ("delete %ls all quiet" wheredir))
  80.    (delete ("%ls.info" wheredir))
  81.    (delete "libs:thumbnail.library")
  82.    (delete "sys:wbstartup/MagicServer")
  83.    (delete "sys:wbstartup/MagicServer.info")
  84.  
  85.    ; Remove stuff from user-startup
  86.    (startup theassign
  87.       (prompt "Somes lines pertaining to ImageFX will now be removed from your user-startup file.")
  88.       (help @startup-help)
  89.       (command "")
  90.    )
  91.  
  92.    ; There is also ImageFX information in ENV:AmigaGuide/Path which should
  93.    ; be removed.  Unfortunately there is no way to do this with an installer
  94.    ; script.
  95.  
  96.    ; Installation complete!
  97. )
  98.  
  99. ;-----------------------------------------------------------------------
  100. ; Revision History:
  101. ;
  102. ;  03.03.95 tek   Created.
  103. ;  11.04.95 tek   Cleaned up for beta release.
  104.